package com.learning.dubbo.service.validation.provider;

import com.learning.dubbo.service.validation.api.ValidationParameter;
import com.learning.dubbo.service.validation.api.ValidationService;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

/**
 * ClassName: ValidationServiceImpl
 * Description:
 * Date: 2020/7/2 10:11 【需求编号】
 *
 * @author Sam Sho
 * @version V1.0.0
 */
public class ValidationServiceImpl implements ValidationService {
    @Override
    public void save(ValidationParameter parameter) {
        System.out.println(parameter.toString());
    }

    @Override
    public void update(ValidationParameter parameter) {
        System.out.println(parameter.toString());
    }

    @Override
    public void insert(@NotNull ValidationParameter parameter) {
        System.out.println(parameter.toString());
    }

    @Override
    public void delete(@Min(1) int id) {
        System.out.println(id);
    }
}
